<?php

class tsw_tempRecordLow implements ThermdSingleWidget
{
  public function drawWidget($io,$x,$y)
  {	
    $ice = imagecolorallocate($io,0,120,255);
    $black = imagecolorallocate($io,0,0,0);
    $icon = imagecreatefrompng(ThermdStats::$thermosrc.'record-low.png');
    // x = 225, y = 56
		$min = ThermdStats::ts_readAllTimeMin(ThermdStats::$temperature_log_id);	
		imagestring($io,4,$x+115,$y+5,$min[1].ThermdStats::$units,$ice);
		imagestring($io,1,$x+15,$y+4,"RECORD LOW",$black);
		imagestring($io,1,$x,$y+12,$min[0],$black);
		imagecopy($io,$icon,$x+86,$y,0,0,24,24);
  }
}

?>